home *** CD-ROM | disk | FTP | other *** search
/ The Fatted Calf / The Fatted Calf.iso / Applications / Communication / NewsBase / Source / INNTP.h < prev    next >
Text File  |  1993-01-12  |  2KB  |  76 lines

  1. /*$Copyright:
  2.  * Copyright (C) 1992.5.22. Recruit Co.,Ltd. 
  3.  * Institute for Supercomputing Research
  4.  * All rights reserved.
  5.  * NewsBase  by ISR, Kazuto MIYAI, Gary ARAKAKI, Katsunori SUZUKI, Kok-meng Lue
  6.  *
  7.  * You may freely copy, distribute and reuse the code in this program under 
  8.  * following conditions.
  9.  * - to include this notice in the source code, if it is to be distributed 
  10.  *   with source code.
  11.  * - to add the file named "COPYING" within the code, which shall include 
  12.  *   GNU GENERAL PUBLIC LICENSE(*).
  13.  * - to display an acknowledgement in binary code as follows: "This product
  14.  *   includes software developed by Recruit Co.,Ltd., ISR."
  15.  * - to display a notice which shall state that the users may freely copy,
  16.  *   distribute and reuse the code in this program under GNU GENERAL PUBLIC
  17.  *   LICENSE(*)
  18.  * - to indicate the way to access the copy of GNU GENERAL PUBLIC LICENSE(*)
  19.  *
  20.  *   (*)GNU GENERAL PUBLIC LICENSE is stored in the file named COPYING
  21.  * 
  22.  * THIS SOFTWARE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR IMPLIED
  23.  * WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED WARRANTIES OF
  24.  * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
  25. $*/
  26. /*
  27.  *    INNTP
  28.  */
  29.  
  30. //#import <objc/Object.h>
  31. #import "IIOmodule.h"
  32. #import <stdio.h>
  33.  
  34. #define        LINE_BUFFER_SIZE    512
  35.  
  36. //@interface INNTP:Object
  37. @interface INNTP:IIOmodule
  38. {
  39.     int        nntpSocket;
  40.     FILE    *inntpFile;
  41.     id        iResBufStorage;
  42.     char    iresponse[LINE_BUFFER_SIZE];
  43.     int        iStatusCode;
  44.     char    *iNntpHostName;
  45. }
  46.  
  47. - init;                            /* init routine */
  48.  
  49. - (int)issueCommand:(const char *)command;
  50. /*
  51.  *  issue a command to nntp ( internal method )
  52.  */
  53.  
  54. - (int)_getResponse;
  55. /*  internal use only
  56.  *  get status and text response from server ( internal method )
  57.  *      return:    status( NULL=error )
  58.  */
  59.  
  60. - openServer:(const char *)serverName;
  61. /*
  62.  *   open a nntp server
  63.  */
  64.  
  65. - (char *)lastResponse;
  66. /*
  67.  *  return obj id that has text response
  68.  *    return:    iresponse
  69.  */
  70.  
  71. - reconnectServer;
  72.  
  73. - free;
  74.  
  75. @end
  76.